<div class="layui-row layui-col-space15" id="recharge">
	<div class="layui-col-md12">
		<div class="layui-card hxr-layui-card">
			<!-- <div class="layui-form hxradmin-card-header">
				<div class="layui-form-item">
					<div class="layui-inline">
						<label class="layui-form-label">会员姓名</label>
						<div class="layui-input-inline">
							<input type="text" name="users" placeholder="请输入会员姓名" autocomplete="off" class="layui-input">
						</div>
					</div>
					<div class="layui-inline">
						<button class="layui-btn" data-type="reload" id="searchs">搜索</button>
					</div>
				</div>
			</div> -->
			<div class="layui-card-body">
				<table class="layui-hide" id="list-select-table" lay-filter="list-select-table"></table>
				<script type="text/html" id="status">
				  {{#  if(d.status === 1){ }}
					<span class="layui-badge layui-bg-green">已支付</span>
				  {{#  } else if(d.status === 2) { }}
				    <span class="layui-badge">未支付</span>
				  {{#  } }}
				</script>
			</div>
		</div>
	</div>
</div>
<script>
	//表格数据渲染
	layui.use(['table', 'form'], function() {
		var table = layui.table,
			form = layui.form,
			$ = layui.$;
			layui.admin.initlist(table,'members/recharge_list',350,[
				[ {
					field: 'recharge_id',
					title: 'ID',
					width: 60
				}, {
					field: 'recharge_sn',
					title: '支付单编号',
					minWidth: 180
				}, {
					field: 'pay_money',
					title: '支付金额(元)',
					width: 110
				},{
					field: 'give_money',
					title: '赠送金额(元)',
					width: 110
				},{
					field: 'status',
					title: '支付状态',
					width: 100,
					templet:'#status'
				},{
					field: 'pay_name',
					title: '支付方式',
					width: 100
				},{
					field: 'create_time',
					title: '创建时间',
					width: 170
				},{
					field: 'pay_time',
					title: '支付时间',
					width: 170
				}]
			],'#list-select-table',509);
			/* table.reload('list-select-table', {
				page: {
					curr: 1
				},
				where: {
					member_id: layui.admin.objData.detail.member_id
				}
			}); */
		//搜索
		// $('#searchs').on('click', function() {
		// 	var val1 = $('input[name="users"]').val()
		// 	//执行重载
		// 	table.reload('list-select-table', {
		// 		page: {
		// 			curr: 1 //重新从第 1 页开始
		// 		},
		// 		where: {
		// 			search_text: val1
		// 		}
		// 	});
		// });
	});
</script>
